<div class="breadcrumb"><?php echo $this->lang->line("menu_contact"); ?></div>

	<div class="register" >
<?php
	$vals = array(
   'img_path' => './images/captcha/',
   'img_url' => base_url() . 'images/captcha/',
   'img_width' => 150,
   'img_height' => 30
);
$capt =create_captcha($vals);
set_secure_code($capt['word']);
$form = array("id"=>"customForm","name"=> "form_tt");

//echo form_open('javascript:send_contact();',$form); ?>

<form action="javascript:send_contact();" method="POST">
 
        	<?php 
	/*		  if(isset($missing) && is_array($missing) )
		   {
		  echo '<p class="title">Lỗi</p>';
		   echo "<div class='error' style='text-align:center'>";
		   foreach($missing as $item)
		   {
				echo $item."<br />";
		   }
		   echo "</div>";
		   }
			
		*/	
			//================THÔNG TIN XÁC THỰC================

  echo '<p class=""></p>';

 

  




  //================THÔNG TIN CÁ NHÂN================

 // echo '<p class="title">THÔNG TIN CÁ NHÂN</p>';

 $cus_name =$this->session->userdata("name");


  //Họ lót

	echo '<div class="inner">';

  $code = 'name';

  $label ='Họ tên ';

 if (! empty($missing) && array_key_exists($code, $missing))

		echo form_label($label, '', array('class'=>'error width-185'));

	else
		echo form_label($label, '', array('class'=>'width-185'));
	
	//echo "Nguyen Van a";
 $data = array("id"=>$code, "name"=>$code,"value"=>$cus_name );
 echo form_input($data,set_value($code));
 if (! empty($missing) && array_key_exists($code, $missing))

			echo '<span id="nameInfo" class="error">'.$missing[$code].'</span>';
else 
			echo '<span id="nameInfo" class="error"></span>';
	echo '</div>';
	
	
	echo '<div class="inner">';

  $code = 'email';

  $label = 'Email';

 if (! empty($missing) && array_key_exists($code, $missing))

		echo form_label($label, '', array('class'=>'error width-185'));

	else
		echo form_label($label, '', array('class'=>'width-185'));
	
	//echo "Nguyen Van a";
 $data = array("id"=>$code, "name"=>$code,"value"=>$cus_name ,set_value($code));
 echo form_input($data);
  if (! empty($missing) && array_key_exists('email', $missing))

			echo '<span id="emailInfo" class="error">'.$missing['email'].'</span>';

		else
			echo '<span id="emailInfo"></span>';	
	echo '</div>';




 


 

  //Di động

	echo '<div class="inner">';

  $code = 'title';

  $label = "Tiêu đề";
if (! empty($missing) && array_key_exists($code, $missing))

		echo form_label($label, '', array('class'=>'error width-185'));

	else
  echo form_label($label, '', array('class'=>'width-185'));
 $data = array('name'=>$code,'id'=>$code, 'class'=>'width-530');
 echo form_input($data,set_value($code));
  if (! empty($missing) && array_key_exists($code, $missing))
{
echo "<div>";
			echo '<span id="titleInfo" class="error">'.$missing[$code].'</span>';
echo "<div>";
}
		else
			echo '<span id="titleInfo"></span>';
	echo '</div>';

echo '<div class="inner">';
 $code = 'detail';

  $label = "Nội dung";
  
if (! empty($missing) && array_key_exists($code, $missing))
	{
		
		echo form_label($label, '', array('class'=>'error width-185'));
		echo "</div>";
	}
	else
	
  echo form_label($label, '', array('class'=>'width-185'));
	$data= array("id"=>$code,"name"=>$code,"cols"=>"25" ,"rows"=>"10");
	//echo form_textarea($data,set_value($data));
	
	
	echo '<textarea cols="20" rows="5" name="detail" id="detail" style="width:250px;" ></textarea>';
  if (! empty($missing) && array_key_exists($code, $missing))

			echo '<span id="cmtInfo" class="error">'.$missing[$code].'</span>';

		else
			echo '<span id="emailInfo"></span>';
echo '</div>';
 echo  form_label("&nbsp;&nbsp;&nbsp;");  echo $capt["image"];
echo '<div class="inner"> ';
$code = 'secure_code';
$label = 'Secure Code';
	if (! empty($missing) && array_key_exists('secure_code', $missing))

		echo form_label($label, '', array('class'=>'error width-185'));

	else
			echo form_label($label, '', array('class'=>'width-195'));
	$data= array("id"=>$code,"name"=>$code,"cols"=>"25" ,"rows"=>"10");
 echo form_input($data,set_value($code));


if (! empty($missing) && array_key_exists($code, $missing))

			echo '<span id="secureInfo" class="error">'.$missing[$code].'</span>';

		else
			echo '<span id="secureInfo">*</span>';
echo '</div>';






?>

<div class="inner" style="margin-left:5px;">
<input style="margin-left:129px;height:29px;border:none;" type="submit" value="gửi"   name="send" id="send" /> &nbsp;&nbsp;&nbsp;&nbsp;

</div>

<?php

	echo form_close(); //FORM END

?>
			
		
            
        
        </div>
                   